<?php require_once "henry.php"; $Henry->registerRegister(); ?>
<?php $Henry->header(); ?>

<section id="messages"><p><?php $Henry->messages(); ?></p></section>

<section class=login>
	<header>
		<h1>Login</h1>
	</header>
	<form method=post>
		<input type=hidden name=action value=login>
		<label for=fname>Email: <input type=email name=email></label>
		<label for=fname>Password: <input type=password name=password></label>
		<input type=submit value="<?php $Henry->out('loginsubmit','language'); ?>">
	</form>
</section>

<?php if($Henry->loginFailed()): ?>
	<section class=loginfailed>
		<header>
			<h1>Recover Password</h1>	
		</header>
		<form method=post>
			<input type=hidden name=action value=resetpassword>	
			<label for=email>Email: <input type=email name=email value="<?php echo $_POST['email']; ?>"></label>
			<input type=submit value="<?php $Henry->out('resetmypasssubmit','language'); ?>">
		</form>
	</section>
<?php endif; ?>

<section id=register>
	<header>
		<h1>Register</h1>
	</header>
	<form method=post>
		<input type=hidden name=action value=register>
		<label for=fname>First Name: <input type=text name=fname></label>
		<label for=lname>Last Name: <input type=text name=lname></label>
		<label for=email>Email: <input type=email name=email></label>
		<label for=password1>Password: <input type=password name=password1></label>
		<label for=password2>Password (again): <input type=password name=password2></label>
		<input type=submit value="<?php $Henry->out('registersubmit','language'); ?>">
	</form>
</section>

<?php $Henry->footer(); ?>
